﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage" %>

<asp:Content ContentPlaceHolderID="TitleContent" runat="server">
    <%=Html.PageTitle(FileLanguage.rename_file_or_folder,"/") %>
</asp:Content>
<asp:Content ContentPlaceHolderID="MainContent" runat="server">
<%string path = (string)ViewData["dir"]; %>
    <%= Html.ValidationSummary(FileLanguage.error)%>
    <h2>
        <%=FileLanguage.rename_file_or_folder %></h2>
    <table>
        <tr>
            <th class="rootfolder">
                <%=Html.MytripImageLink(Url.Action("Index",new{id=string.Empty}),
                "/Content/files/Stuffed_Folder.png", Membership.ApplicationName,0,32,0) %>
            </th>
            <th>
                <%= Html.ActionLink(Membership.ApplicationName, "Index", new { id = string.Empty })%>
                <%=Html.MytripDirectory(path)%>
            </th>
        </tr>
    </table>
    <table>
        <tr>
            <% using (Html.BeginForm("Rename", "File", new { id = path, t = Request.QueryString["t"] }))
               {%>
            <td>
                <p>
                    <%=FileLanguage.choose_new_name %></p>
                <p>
                    <%= Html.TextBox("name", ViewData["name"].ToString())%></p>
                <p>
                    <%=Html.MytripInput("submit", FileLanguage.rename) %></p>
            </td>
            <% } %>
        </tr>
    </table>
    <%=Html.MytripActionLink(Url.Action("Index", "File", new{id=path.Remove(path.LastIndexOf("()"))}),FileLanguage.back_to_list) %>
</asp:Content>
